    <h2 class="title">个人头像</h2>

    <div class="upload">
        <div class="img-wrap">
            <img      <{if $user.userIcon=='' and $user.userGender=='m'}>
                      src="/upload/upload/images/nousericon-m.png"
                      <{elseif $user.userIcon=='' and $user.userGender=='f'}>
                      src="/upload/upload/images/nousericon-f.png"              
                      <{elseif $user.userIcon=='' and $user.userGender==''}>
                      src="/upload/upload/images/nousericon-m.png"
                      <{else}>src="<{$user.userIcon}>"
                      <{/if}> class="img" id="imgId">
        </div>
        <div class="content">
            <p class="text">清楚的脸部正面照对导游和游客了解彼此起着重大作用，请上传一张能清楚看到您脸部的照片。</p>
           <div class="img-right">
    <img src="/upload/upload/images/guide_info_upload_right.png">
  </div>
  <div class="img-wrong">
   <img src="/upload/upload/images/guide_info_upload_wrong.png">
</div>

        </div>
    </div>

    <h2 class="title">个人信息</h2>

    <div class="youkexinxi">
        <p class="tishi">温馨提示：为了便于哇吖对您的身份识别，保证旅行的安全，请填写真实姓名。</p>
        <label class="stablelabel">
            <span class="text">姓氏</span>
           <!-- <input type="text" name="userFamily" value="<{$user.userFamily}>" placeholder="例如：张" class="shurk">-->
            <span class="stableshurk">
            <{if $user.userFamily == ''}>
            待补充
            <{else}>
            <{$user.userFamily}>
            <{/if}>
            </span>
        </label>
        <label class="stablelabel">
            <span class="text">名字</span>
            <span class="stableshurk">
            <{if $user.userName == ''}>
            待补充
            <{else}>
            <{$user.userName}>
            <{/if}>
            </span>
        </label>
        <label class="stablelabel">
            <span class="text">性别</span>
            <span class="stableshurk">
            <{if $user.userGender == 'm'}>男
            <{elseif $user.userGender == 'f'}>女
            <{else}>待补充
            <{/if}>
            </span>
        </label>
        <label class="stablelabel ">
            <span class="text">年龄</span>
            <span class="stableshurk">
            <{if $user.userAge == '70后'}>70后
            <{elseif $user.userAge == '80后'}>80后
            <{elseif $user.userAge == '90后'}>90后
            <{elseif $user.userAge == '00后'}>00后
            <{else}>待补充
            <{/if}>
        </label>
        <label class="stablelabel">
            <span class="text">电话</span>
            <span class="stableshurk">
            <{if $user.userPhone == ''}>
            待补充
            <{else}>
            <{$user.userPhone}>
            <{/if}>
            </span>
        </label>

          <a href="/tourist/update_user_info/<{$user.uid}>"><div class="submit" style="cursor:pointer;">编辑</div></a>
    </div>


<script>

    function showXiala(item) {

        $(item).parent().find('.xiala').show();

        $(item).parent().find('.li').each(function() {

            $(this).on('click',function() {
                $(item).val($(this).val());
                $(item).parent().find('.xiala').hide();
                return false;
            });


        });

    }
    $("#userHeadImg").change(function(event) {
        var file = $(event.target)[0].files[0];
        var src = URL.createObjectURL(file);
        if(file){
            $("#imgId").attr('src',src)
            //表示获取到了图片
        }else{
            //表示点击了取消
            $("#imgId").attr('src',"<{$user.userIcon}>")
        }
        //这里的src就是图片的地址，将它放在任意一个img标签的src属性里面
    });

    $(".info").addClass("active");

</script>

